GetGray
GetGray
Get best available intermediate color GDHandle device; a handle to the device
const RGBColor *backGround background color The GetGray function provides your application with the best intermediate color in RGB space that is available for a given device
device handle to the graphics device
backGround the background color for which you want the best intermediate RGB
color
foreGround the foreground color for which you want the best intermediate RGB
color
Notes: One use for GetGray is to return the best gray, as when dimming a menu
item: supply black and white as the two colors, and GetGray returns the best
available gray that lies between them.
If no gray is available (or, if you supplied two colors, no distinguishable
third color is available), the foreGround parameter is un changed, and the
function returns FALSE. If at least one gray or intermediate color is
available, it or the best one is stored in the foreGround parameter, and the
function returns TRUE.